# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python2-ipython-genutils
_pkgname=ipython_genutils
pkgver=0.2.0
pkgrel=2
pkgdesc='Vestigial utilities from IPython.'
arch=('any')
url='https://pypi.org/project/ipython_genutils'
license=('BSD')
depends=('python2')
makedepends=('python2-setuptools')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('0e5a9f8be17d98dfb74ec77d1360ee79276a13fe1914e6d31e8740f06375ed1671c49356a77f118495f50823b8384c1e2c5b6fae73965e3d4249c831b9a2b095')

build() {
  cd "$_pkgname-$pkgver"

  python2 setup.py build
}

package() {
  cd "$_pkgname-$pkgver"

  python2 setup.py install --root="$pkgdir" --prefix=/usr -O1 --skip-build

  install -Dm 644 COPYING.md "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}

